home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-04 / osg.zip / README.105 < prev   
Text File  |  1990-12-10  |  62KB  |  1,527 lines

  1. .PL
  2.                       Object Code SCREEN GENERATOR - OSG
  3.  
  4.  
  5.  
  6.  
  7.  
  8.                                  Distributed by
  9.                            Inventories Unlimited Inc.
  10.                              222 Church Street - 5g
  11.                               Philadelphia PA 19106
  12.                                  (215) 922-2557
  13.                       Data: (215) 627-3910 (PC Pursuitable)
  14.  
  15.                      Version 1.05, Released 10 October 1987
  16.  
  17.  
  18.         Microsoft,  MS,  QuickBASIC, CodeView and MS-DOS  are  registered 
  19.                       trademarks of Microsoft Corporation.
  20.  
  21.                  CLIPPER is a registered trademark of Nantucket.
  22.  
  23.  
  24.  
  25.  
  26.  
  27.  
  28.  
  29.  
  30.  
  31.  
  32.  
  33.  
  34.  
  35.  
  36.  
  37.  
  38.  
  39.  
  40.  
  41.  
  42.  
  43.  
  44.  
  45.  
  46.  
  47.  
  48.  
  49.  
  50.  
  51.  
  52.  
  53.  
  54.  
  55.  
  56.  
  57.  
  58.  
  59.  
  60.  
  61.  
  62.                     (c) 1987 Roy Barrow & Douglas H. Steen         1
  63.                       Object Code SCREEN GENERATOR - OSG
  64.  
  65.  
  66.                      OSG consists of the following programs:
  67.  
  68.                             OSG.EXE - Screen Definer
  69.                    OSGBASIC.EXE - QuickBASIC Input Definition
  70.  
  71.                          and of the following libraries
  72.  
  73.                             OSG.LIB - Screen Drivers
  74.                     OSGINPUT.LIB - Input Modules (QuickBASIC)
  75.  
  76.         Check  that your ARCHIVE or DISTRIBUTION disk contains the  above 
  77.         programs  and  linraries. NOTE that OSGINPUT.LIB  is  distributed 
  78.         only with the commercial version.
  79.  
  80.                                   Introduction
  81.  
  82.         OSG  was  first released in August of 1987. Since then,  we  have 
  83.         added features that users have requested and some of our own.  We 
  84.         fixed  whatever bugs were reported to us, and developed a  series 
  85.         of support programs. We would like to thank the following  people 
  86.         for their invaluable contribution in testing and suggesting!
  87.  
  88.         Derron  Simon,  Dan Ashler, John Ferguson, Steve  Skindell,  Chip 
  89.         Rabinowitz.
  90.  
  91.                            What does OSG accomplish ?
  92.  
  93.         Firstly,  OSG is a full featured screen generator. Any  free-form 
  94.         screen may be designed. This screen can be saved, and then called 
  95.         back  later  for  modification. An option exists  to  OUTPUT  the 
  96.         screen  to  an  ASCII  file  for  inclusion  with  your   program 
  97.         documentation.
  98.  
  99.         The  purpose  of  OSG  is not  always  clear.  It  was  initially 
  100.         developed  for  QuickBASIC programmers so that screens  could  be 
  101.         stored  out of the string  data segment. QuickBASIC's severe  64K 
  102.         string segment limitation, and the speed in which QB updated  the 
  103.         display, were two major obstacles that needed overcoming.
  104.  
  105.         OSG's  initial  output was in the form of Macro  Assembler  code. 
  106.         This  in its'self was a limitation as we found that  many  people 
  107.         either did not have the Macro Assmebler, or did, but had no  idea 
  108.         how to use it !
  109.  
  110.         OSG  then  changed  direction and produced  .OBJ  file  (INTEL  / 
  111.         Microsoft  format)  that may be linked  into  applications.  (See 
  112.         technical information for more details).
  113.  
  114.         Along  with  the .OBJ file created, provided is a  screen  driver 
  115.         library that also needs linking to your application. The overhead 
  116.         for the module(s) is less than 800 bytes in total.
  117.  
  118.         This same .OBJ file is language independant, and may be  utilized 
  119.         in languages that allow INTEL / Microsoft Relocatable Object file 
  120.         linking.
  121.  
  122.  
  123.                     (c) 1987 Roy Barrow & Douglas H. Steen         2
  124.                       Object Code SCREEN GENERATOR - OSG
  125.  
  126.  
  127.  
  128.                            Among these languages are:
  129.  
  130.         Microsoft QuickBASIC
  131.         Microsoft Assembler
  132.         Microsoft C
  133.         Microsoft PASCAL
  134.         Microsoft FORTRAN
  135.              
  136.         BORLAND TURBO C
  137.         MANX AZTEC C
  138.         DATALIGHT C
  139.  
  140.         NANTUCKET CLIPPER
  141.              
  142.         although,  as a general rule, if you language allows  linking  to 
  143.         external  ASSEMBLY  language routines (in .OBJ format)  then  you 
  144.         should have no problems in using OSG
  145.  
  146.                              What else does OSG do ?
  147.  
  148.         OSG  includes a utility program called OSGBASIC which  is  purely 
  149.         for QuickBASIC users.
  150.  
  151.         OSGBASIC  is a utility that allows the user to call up  a  screen 
  152.         image  and  then define input points upon that  screen.  OSGBASIC 
  153.         then  goes ahead and generates program code that will do  all  of 
  154.         the input as defined.
  155.  
  156.                  An appendix contains documentation on OSGBASIC.
  157.  
  158.                              Documentation Standards
  159.  
  160.         If you see a block of text with braces around it (like  {RETURN})  
  161.         then  you  know that this refers to a SINGLE key stroke  or  ALT,  
  162.         SHIFT or CTRL combination. The above illustration means that  you  
  163.         have  pressed the {RETURN} or {ENTER} key; other  clear  examples  
  164.         are {ESC} (the escape key), or {F1} (function key one).
  165.  
  166.         An  ALT,  CTRL or SHIFT combination is  highlighted  as  {ALT+A}, 
  167.         where   the '+' indicates that BOTH ALT and A should  be  pressed 
  168.         (hold  down the ALT key and press A).
  169.  
  170.                                  Installing OSG
  171.  
  172.         You will need the following hardware to use OSG effectively.
  173.  
  174.         IBM  PC,  PC/XT, PC/AT, PS2 and all compatibles thereof  with  at 
  175.         least 320K
  176.         Monochrome, CGA or EGA
  177.         Two floppy disks (Hard Disk recommended)
  178.  
  179.         and, the following software
  180.  
  181.         Language supporting INTEL / MICROSOFT Relocatable Object Files
  182.  
  183.  
  184.                     (c) 1987 Roy Barrow & Douglas H. Steen         3
  185.                       Object Code SCREEN GENERATOR - OSG
  186.  
  187.  
  188.  
  189.                To install OSG, you will need the following files:
  190.  
  191.         OSG.EXE (OSG Program)
  192.         OSG.LIB (OSG Library, screen drivers)
  193.  
  194.         (You  may also want to install OSGBASIC and OSGINPUT.LIB  in  the 
  195.         same way)
  196.  
  197.                       With these in-hand, do the following:
  198.  
  199.         Create  a  directory  that will be used in  storing  your  screen 
  200.         files. Both the .OSC (Image Format) and .OBJ files will reside in 
  201.         this directory.
  202.  
  203.               Copy your OSG.EXE and OSG.LIB file to this directory.
  204.  
  205.         As  you  create .OBJ files from images, you may want to  (if  you 
  206.         have  the  LIB utility program) add these files  to  the  OSG.LIB 
  207.         file.
  208.  
  209.         The \SCREENS directory has now been created. Don't add it to your 
  210.         PATH  or you are bound to end up having .OSC files all  over  the 
  211.         place.
  212.  
  213.                                     Using OSG
  214.  
  215.         Running OSG is simple. Type OSG from the DOS prompt, and away you 
  216.         go.
  217.  
  218.         You can get past the initial startup screen by pressing ENTER. 
  219.  
  220.         At  this  point,  you are ready to start defining  a  screen.  By 
  221.         typing  and  using the normal control keys, you will be  able  to 
  222.         navigate your way around the display.
  223.  
  224.         Normal  typing (characters that have a one key combination  entry  
  225.         and  do not include function keys) will produce  characters  upon  
  226.         the  screen - wrapping when the end of the line is  reached,  and  
  227.         wrapping  around  to  the top when the bottom of  the  screen  is  
  228.         reached.
  229.  
  230.         In  this fashion, the cursor, delete, insert and  backspace  keys  
  231.         work  in  the same fashion you would expect an editor to.  A  few 
  232.         moments   of  typing and using these keys will give you  all  the 
  233.         training you  need on getting around the screen.
  234.  
  235.         Some  other editing keys that exist are perhaps not so clear,  or  
  236.         are handled differently in this program than others you might  be  
  237.         used to.
  238.  
  239.         {PageUp}  and  {PageDown}  will move the cursor to  the  top  and 
  240.         bottom  of the screen, respectively.
  241.  
  242.         {Home} and {End} will move the cursor to the top left hand corner 
  243.  
  244.  
  245.                     (c) 1987 Roy Barrow & Douglas H. Steen         4
  246.                       Object Code SCREEN GENERATOR - OSG
  247.  
  248.  
  249.         and  the bottom right hand corner, respectively.
  250.  
  251.         {Control + Right arrow}, and {control + Left arrow} will move the  
  252.         cursor  to  the  right  and  left  hand  sides  of  the   screen, 
  253.         respectively.
  254.  
  255.         In  addition,  the default TAB settings are  placed  five  spaces  
  256.         apart, and may be used by pressing the {TAB} key and  {SHIFT+TAB} 
  257.         for  backwards movement.
  258.  
  259.         Two  other  'movement' controls exist that do not  fit  into  the  
  260.         discussion here, but will be mentioned for completeness.
  261.  
  262.         {ALT+K) will move the cursor BACK to a previous word, and {ALT+W} 
  263.         will move it forward to the next word.
  264.  
  265.         The   function  keys  (f1  through  f10)  may  be  assigned   key 
  266.         combinations. This is discussed under MACRO DEFINITIONS.
  267.  
  268.         When you are ready to create an OBJECT file from a screen  image, 
  269.         read the section entitled OBJECT FILES.
  270.  
  271.         The  technical  details appendix describes the OBJ file  and  OSC 
  272.         file formats and storage methods. This section of the manual also 
  273.         includes the assembly language source for the screen drivers.
  274.  
  275.         Now, there are numerous control keys that will assist in creating 
  276.         screens, and we'll discuss them one by one.
  277.  
  278.                                Individual Options
  279.  
  280.         OSG  incorporates an on-line help facility. This should make  the 
  281.         program easier to use, although no product is complete without  a 
  282.         manual.
  283.  
  284.         The  format for the rest of this manual involves a discussion  of 
  285.         the  options  available,  supported  by  their  respective   help 
  286.         screens.
  287.  
  288.                   ALTERING THE VIEWPORT / ADJUSTING BOUNDARIES.
  289.  
  290.         Normally, the screen that you will be working with is 80  columns  
  291.         by  24 rows. The last row on the screen (25) is reserved for  OSG  
  292.         status use.
  293.  
  294.         You  may  narrow this viewport so that most of the  actions  that  
  295.         you take will affect only this area of the screen.
  296.  
  297.         To  modify the viewport, the combination {ALT+A} must be  chosen.  
  298.         This  is  the  standard  command  issuing  sequence.  {ALT+A}  is  
  299.         accomplished by holding down the ALT key and pressing A.
  300.  
  301.         A  box  or rectangle will then open up on the  screen.  You  will  
  302.         notice that one of the corners is highlighted with a double width  
  303.         drawing  character.  This  is  the ACTION  corner  -  any  cursor  
  304.  
  305.  
  306.                     (c) 1987 Roy Barrow & Douglas H. Steen         5
  307.                       Object Code SCREEN GENERATOR - OSG
  308.  
  309.  
  310.         controls  issued  will affect this corner. You may now  move  the  
  311.         sides of the screen to where you want it by selecting the  cursor  
  312.         keys.  To move the highlight (or ACTION corner), press the  {TAB} 
  313.         key and you will notice the highlight move clockwise.
  314.  
  315.         You may also move the box around the screen by first pressing the  
  316.         {SCROLL  LOCK}  key  and then using the  CURSOR  or  ARROW  keys. 
  317.         (CURSOR  and ARROW keys have the same meaning in OSG).
  318.  
  319.         When you have sized and moved your VIEWPORT to the point you want  
  320.         it, you may exit the selection by pressing {ESC} or {RETURN}.
  321.  
  322.         Now  try typing and you will notice a different WRAP AROUND -  it  
  323.         now happens at the edges of the view port.
  324.  
  325.         There  are  a number of advantages to  using  different  viewport  
  326.         sizes.  If  you  wish to split the screen into  two  columns  and  
  327.         place  information in one, and then information in  another,  you  
  328.         will  know that most of the editing that you do will only  affect  
  329.         the current viewport.
  330.  
  331.         The  viewport  is changed by using the  'box  selection  method'. 
  332.         Please refer to 'Box Selection in the appendix'
  333.  
  334.         OSG  is  initiated with boundaries (or margins) set as  the  full 
  335.         screen. The bottom line of the screen cannot be used - this is  a 
  336.         status line. 
  337.  
  338.         There are two options in changing boundaries:
  339.  
  340.                         ADJUST screen Boundaries {ALT+A}                                               
  341.  
  342.         A rectangular selection box appears in the center of the  screen. 
  343.         This  box is manipulated (see Box Selection), and an area of  the 
  344.         screen  is clipped. This clipped area now defines the  'viewport' 
  345.         that all subsequent operations will take affect in.
  346.  
  347.         EXPLODE to full
  348.  
  349.         A  rectangular selection box appears at the edges of the  screen. 
  350.         This  boundary  can simply be set by pressing ESC  or  ENTER,  or 
  351.         manipulated.
  352.  
  353.                       CHARACTER TOGGLE FOR NUMERICS {ALT+C}
  354.  
  355.         The  numeric keypad, either at the right hand of  the  typewriter  
  356.         pad  or  on the typewriter pad may be used  in  placing   graphic 
  357.         characters upon the screen. (Graphic drawing characters).
  358.  
  359.         To toggle this character mapping on or off, the {ALT+C}  combina-
  360.         tion is used.
  361.  
  362.         By  using the Numeric Character Mapping option, a number  of  the 
  363.         graphic drawing characters may be mapped onto the numeric keypad. 
  364.         The definitions mapped are either single or double line types  as 
  365.  
  366.  
  367.                     (c) 1987 Roy Barrow & Douglas H. Steen         6
  368.                       Object Code SCREEN GENERATOR - OSG
  369.  
  370.  
  371.         selected by GRAPHIC DRAWING SET option. 
  372.  
  373.         Turn this option on and test the mapping functions.
  374.  
  375.                                  DRAWING {ALT+D}
  376.  
  377.         After the drawing toggle is selected, only arrow keys may be used 
  378.         in  moving the cursor around the screen. A trail of  the  drawing 
  379.         characters will follow on the screen. When crossing, or  adjacent 
  380.         to  other  characters, OSG will determine what it thinks  is  the 
  381.         correct  character. As this does not always produce  the  desired 
  382.         results, an option to place any character (from the IBM character 
  383.         set) has been included. (Invoke this with a CTRL-A  combination).   
  384.  
  385.         What  character  is  produced depends upon  the  current  drawing 
  386.         character  type selection. (See Graphic drawing set  Change).  It 
  387.         will  be either a double or single line graphic character  value. 
  388.         To exit from DRAW mode, a RETURN or ESC key must be pressed. If a 
  389.         RETURN  key  is pressed, then the cursor will move  down  to  the 
  390.         start of the next line. 
  391.  
  392.         Drawing  is  disabled  during MACRO execution.  Drawing  is  only 
  393.         controllable from the keyboard.
  394.  
  395.                            ERASE ROW or COLUMN {ALT+E}
  396.  
  397.         Either  the column or row at the current cursor position  may  be 
  398.         deleted.  If COLUMN is selected, then the current column will  be 
  399.         erased,  and all of the columns to the RIGHT of the  current  row 
  400.         will be moved left by one column. 
  401.  
  402.         When deleting a ROW, all of the lines BELOW the one being deleted 
  403.         will be moved up by one. Notice that the ERASE function (as  with 
  404.         most  functions  inside  of OSG) will  only  affect  the  current 
  405.         viewport  defined by the ADJUST BOUNDARIES option.  
  406.  
  407.         Commands  for  ERASE ROW and COLUMN may be  embedded  into  MACRO 
  408.         definitions. The bottom row or right most column that is added to 
  409.         the  file will be filled with Blanks. This only  determines  what 
  410.         the  color will be of future types  characters. All those on  the 
  411.         screen  will  remain  with their  current  colors  /  attributes. 
  412.  
  413.         If  you wanted to scroll a section of the screen up,  you   could 
  414.         select  that area as the viewport, and then just erase a row   at 
  415.         the  top.  Similarly, if you wished to scroll it  left  (or  even  
  416.         right  for  that matter), you could select the area,  and  either  
  417.         delete or insert a column. 
  418.  
  419.                      FOREGROUND and BACKGROUND color {ALT F}
  420.  
  421.         This will determine which colors are to be set for all subsequent 
  422.         typing. Moving the selection box to a specific color  combination 
  423.         and  pressing  ENTER will make this selection. 
  424.  
  425.         A  word  or two of caution here: OSG's screens will  display  the 
  426.  
  427.  
  428.                     (c) 1987 Roy Barrow & Douglas H. Steen         7
  429.                       Object Code SCREEN GENERATOR - OSG
  430.  
  431.  
  432.         attributes  that  you select upon a variety  of  monitors.   What 
  433.         appears  on  an EGA will differ from a CGA, which  in  turn  will 
  434.         differ  from  a Monochrome Display. It is only  by  experimenting 
  435.         that you will decide which are the correct color combinations  to 
  436.         use  in  your  programs,  determined  largely  by  the  programs' 
  437.         intended  audience.  
  438.  
  439.         The  screens throughout OSG have been left Monochrome. This  does 
  440.         not  detract  from the programs' appearance. It  just  makes  the 
  441.         usage of it more universal. 
  442.  
  443.         The  "Selecting  a  color" function is used in  other  areas,  so  
  444.         coverage  on making the selection is inserted here  and  referred  
  445.         to from this point on.
  446.  
  447.         A  box  with  highlighted cells (test patterns)  appears  on  the  
  448.         screen with a rectangle highlighting one of them. This  rectangle  
  449.         may be moved from pattern to pattern, upwards and downwards, left  
  450.         and  right  by  using  the cursor  keys.  {Home}  will  move  the  
  451.         selection rectangle to the top left corner, while {END} will take  
  452.         it to the lower right corner.
  453.  
  454.         A color combination for foreground and background is selected  by 
  455.         pressing {ENTER} or {ESC}
  456.  
  457.  
  458.                        GRAPHIC DRAWING SET CHANGE {ALT+G}
  459.  
  460.         This defines what characters will appear  when using DRAW.  Also, 
  461.         if  Character Mapping (for numbers) is ON,  then Number  pressing 
  462.         (or  entries in macros) will produce the  currently toggled  line 
  463.         type character.
  464.  
  465.         You may toggle the Graphic Drawing set between single and  double 
  466.         width  drawing characters. You do not need to remember all  these 
  467.         functions - pressing the  HELP key ALT+H will bring up a  summary 
  468.         of  the functions  available. Pressing the associated letter  for 
  469.         the  key  that  you  need help upon will  display  more  detailed 
  470.         information for that  option.
  471.  
  472.                                 HELP MENU {ALT+H}
  473.  
  474.         The help menu gives a list of the available functions (summarised 
  475.         below)  that  you may seek further help upon. At  any  time  from 
  476.         HELP,  the function key {f10} will return you to the editor.
  477.  
  478.  
  479.         A Adjusting Boundaries
  480.         C Character Toggle for Numerics
  481.         D Drawing
  482.         E Erase Row or Column
  483.         F Foreground and Backround Color
  484.         G Change the Graphic Drawing Set
  485.         H THIS HELP SCREEN
  486.         I Insert Row or Column
  487.  
  488.  
  489.                     (c) 1987 Roy Barrow & Douglas H. Steen         8
  490.                       Object Code SCREEN GENERATOR - OSG
  491.  
  492.  
  493.         J Justify line Left, Right, Center
  494.         L Load screen file into memory
  495.         M Macro Definitions
  496.         N New Screen, Reset this one
  497.         O Object file create
  498.         P Print file create
  499.         Q Quit and save or abandon
  500.         R Replace a character
  501.         S Select and Paste, Erase, Fill
  502.           Invert or Change colors
  503.         T Tab Settings
  504.         V Version and Details
  505.         X Exit to DOS Temporarily
  506.         F1 General Editing Functions
  507.         F2 MACRO Embedded Codes
  508.         F4 Object files - using in your applications
  509.  
  510.                           INSERT ROW or COLUMN {ALT+I}
  511.  
  512.         Either  a  column or row at the current cursor  position  may  be 
  513.         inserted.  
  514.  
  515.         If  COLUMN is selected, then the current column will be moved  to 
  516.         the  right,  and a column of blank characters will  be  inserted. 
  517.         Whatever  was on the last column of the screen, or viewport  will 
  518.         drop off. 
  519.  
  520.         Inserting a row will move the current row (and all rows  beneath) 
  521.         one  line down, with the bottom line of the screen (or  viewport) 
  522.         dropping off the screen. As with ERASE, the commands issued  only 
  523.         take  affect  within the current view-port.  These  commands  for 
  524.         Insert may be embedded into MACRO definitions. The row or  column 
  525.         that is added to the screen will be filled with blanks.
  526.  
  527.                             JUSTIFY  A  LINE {ALT+J}  
  528.  
  529.         As  with a number of features of OSG, it is recommended that  you  
  530.         SAVE your screen image regularly to ensure that an 'edit' is  not 
  531.         fatal.
  532.  
  533.         Justification  of  a line takes place only within  the  currently 
  534.         defined viewport. Three options for JUSTIFY exit - Left, Right or 
  535.         Center.  Justification of a line will trim leading  and  trailing 
  536.         blanks, justify the string in accordance with the choice that you 
  537.         made, then before displaying it, pad the line with either leading 
  538.         or  trailing spaces (both - in the case of Center Justify)  Macro 
  539.         definitions  exist for justification. Justify will  always  leave 
  540.         the  cursor  upon the current row and column. 
  541.  
  542.  
  543.                       LOAD  SCREEN FILE INTO MEMORY {ALT+L}
  544.  
  545.         OSG  gives an extension of .OSC to the files that it creates  for 
  546.         screen  images.  Files created in this fashion may be  read  from 
  547.         disk  to  allow for modifications. (Format of the .OSC  files  is 
  548.  
  549.  
  550.                     (c) 1987 Roy Barrow & Douglas H. Steen         9
  551.                       Object Code SCREEN GENERATOR - OSG
  552.  
  553.  
  554.         discussed in the documentation). 
  555.  
  556.         A  selection  of a file to load is made from a  scroll  box.  The 
  557.         scroll box is 'navigated' with the following keys: 
  558.  
  559.         [up arrow] - Move up one selection 
  560.         [down  arrow] - Move down one selection 
  561.         [page down] - Move down one scroll box 
  562.         [page up] - Move up one scroll box 
  563.         [home] - Move to top of scroll box 
  564.         [end] - Move to end of scroll box 
  565.         [return] - Make selection of currently high-lit item 
  566.         [esc] - Exit scroll box without selection 
  567.  
  568.         If  MERGE  is chosen, then the cells that are NOT  blank  in  the 
  569.         merged file will displace what is on the screen.
  570.  
  571.         To  load a screen image into memory from disk, you  should  press  
  572.         the {ALT+L} combination.
  573.  
  574.         Two load options are available: a COMPLETE load, or a MERGE load.
  575.  
  576.         If  you choose COMPLETE, then the contents of the screen will  be  
  577.         completely  replaced by the screen image loaded. If you  need  to  
  578.         keep  hold of the current screen image, then ensure that you  use  
  579.         the SAVE option before LOADing a screen.
  580.  
  581.         A  MERGE load will do the following: Any character cell  that  is  
  582.         not a space in the file BEING MERGED, will replace what is on the  
  583.         current screen.
  584.  
  585.         MERGE is to be used when bringing in a common  section  (although 
  586.         spaces will be ignored). MERGE is really not  the best way to  do 
  587.         this. If you need to work with a common  section, then use it  as 
  588.         the base for designing a screen. What the  OSC file looks like is 
  589.         not  related  to  the ACTUAL object file.  The  OBJECT  file  can 
  590.         contain  screen primitives and a number of  OBJECT files  (calls) 
  591.         can be used in creating just one screen.
  592.  
  593.         {ALT+L} will either do nothing (in which case you know that there  
  594.         are no files to load), or it will display a scroll box from which  
  595.         you may select a file. These files all have extensions of OSC. If  
  596.         you  are using a program, or set of programs, that already  makes 
  597.         use  of this extension, we suggest setting up OSG in a  directory 
  598.         of  its own. (Actually, we suggest you do this at any rate).
  599.  
  600.  
  601.                             MACRO DEFINITIONS {ALT+M}  
  602.  
  603.         Macros  are common key strokes that you may assign to a  function 
  604.         key.  There are 40 function keys that may be defined.  These  are 
  605.         NORMAL, SHIFT, CTRL and ALT F1 through F10. 
  606.  
  607.         Macro  definitions may have the extended character  set  embedded 
  608.         within.  When  editing a Macro definition, pressing  one  of  the 
  609.  
  610.  
  611.                     (c) 1987 Roy Barrow & Douglas H. Steen         10
  612.                       Object Code SCREEN GENERATOR - OSG
  613.  
  614.  
  615.         function  keys will allow you to insert any of these  characters. 
  616.         Macros  may invoke other macros, and also themselves (there is  a 
  617.         limit of 2000 displayable characters). 
  618.  
  619.         An example of a MACRO definition has been included for you to try 
  620.         out,  and  also as an example. MACROS can be  very  powerful  and 
  621.         productive when used correctly.
  622.  
  623.                               MACRO EMBEDDED CODES
  624.  
  625.         The  Macro codes may be placed into macro definitions. There  are 
  626.         both command and editing macros, and macro key macros. (In  that, 
  627.         we mean that you are able to call a MACRO from a MACRO, even  the 
  628.         calling MACRO).
  629.  
  630.         The format for the MACRO calling is:
  631.  
  632.         \A New Screen
  633.         \B Quit
  634.         \C Character Map
  635.         \D Down Arrow
  636.         \E END
  637.         \F Select Color
  638.         \G Graphic Set
  639.         \H Home
  640.         \I Insert Toggle
  641.         \J (RESERVED)
  642.         \K (RESERVED)
  643.         \L Left Arrow
  644.         \M Merge Screen
  645.         \N Load Screen
  646.         \O Object Create
  647.         \P Print Create
  648.         \Q Quit & Save
  649.         \R Right Arrow
  650.         \S Select & Paste
  651.         \T TAB Settings
  652.         \U Up Arrow
  653.         \V Version
  654.         \W Insert Row
  655.         \X Insert Column
  656.         \Y Erase Row
  657.         \Z Erase Column
  658.         \a Select & Erase
  659.         \b Expand Borders
  660.         \c Justify Center
  661.         \d Delete
  662.         \e Carriage Return
  663.         \f Delete file
  664.         \g Select & fill
  665.         \h Select & Color Change
  666.         \i Select & Invert
  667.         \j Copy Line
  668.         \k Swap Line
  669.         \l Justify left
  670.  
  671.  
  672.                     (c) 1987 Roy Barrow & Douglas H. Steen         11
  673.                       Object Code SCREEN GENERATOR - OSG
  674.  
  675.  
  676.         \m Load Macros
  677.         \n Macro Change
  678.         \o (RESERVED)
  679.         \p (RESERVED)
  680.         \q (RESERVED)
  681.         \r Justify Right
  682.         \s Shift TAB
  683.         \t TAB
  684.         \u (RESERVED)
  685.         \v (RESERVED)
  686.         \w Show 'Whereis'
  687.         \x Shell to DOS
  688.         \y (RESERVED)
  689.         \z (RESERVED)
  690.         \\ '\' Character
  691.  
  692.         The MACRO definitions for calling other Macros are in the  format 
  693.         of:
  694.  
  695.         \nv where
  696.  
  697.         n  would be a value between 1 and 0 (0 indicating 10), and  v  is 
  698.         between A and D, which are A:Normal, B:Shift, C:Control, D:Alt.
  699.  
  700.                             Here are a few examples.
  701.  
  702.         \1A  Normal F1
  703.         \3B  Shift F3
  704.         \0D  ALT F10
  705.         \7C  Control F7
  706.  
  707.         This should be enough .... experiment!
  708.  
  709.  
  710.                                NEW SCREEN {ALT+N}
  711.  
  712.         This  will erase the contents of the currently defined  viewport. 
  713.         Remember  to  increase the boundaries to the full screen  if  you 
  714.         wish to erase the whole screen. The other option that you have is 
  715.         invoking  the  SELECT and ERASE option, and  the  increasing  the 
  716.         selection box to the full screen size. 
  717.  
  718.         This  NEW SCREEN Option has been largely replaced by  the  select 
  719.         and  erase function but has been 'left in' for completion.  Using 
  720.         the selection box is covered in the documentation. 
  721.  
  722.                           OBJECT FILE CREATION {ALT+O}
  723.  
  724.         Two  options  exist when creating OBJ files from  a  screen.  The 
  725.         screen  may  either be STATIC or LOCATABLE. 
  726.  
  727.         STATIC screens will always be displayed back upon the same  point 
  728.         on  the  screen. This is normally used for  whole  screen,  fixed 
  729.         inputs  etc. 
  730.  
  731.  
  732.  
  733.                     (c) 1987 Roy Barrow & Douglas H. Steen         12
  734.                       Object Code SCREEN GENERATOR - OSG
  735.  
  736.  
  737.         LOCATABLE  screens  may  have a ROW,COLUMN  set  of  co-ordinates 
  738.         passsed to them which indicate the top left hand corner. 
  739.  
  740.         This  would  be  typically used in drawing  primitives.  At  that 
  741.         point, one could 'build' a screen or object from these primitives 
  742.         and display them at any point on the screen. 
  743.  
  744.         Dialog boxes, scroll boxes and 'floating' menus come to mind. The 
  745.         OBJ file that is created will have the .OBJ extension, and may be 
  746.         used  in a variety of languages. 
  747.  
  748.         {ALT+O}  invokes Object file creation. Any portion of the  screen  
  749.         (even outside of the current viewport) may be selected for OBJECT  
  750.         creation. (See Box Selection)
  751.  
  752.         In creating an OBJECT file, you may select a RECTANGULAR area  of  
  753.         the screen from a few lines and columns up to the whole   screen. 
  754.         OSG then optimizes the contents of the screen and  squeezes it in 
  755.         the smallest possible format.
  756.  
  757.         If you have a common screen header (i.e. the top 3 lines of   the 
  758.         screen),  then  your best approach would be to create  an  object  
  759.         file  that  has these three lines. Each program,  or  section  of  
  760.         program,  that  displays a screen where this standard  header  is  
  761.         needed, simply places a call to HEADER and then displays the rest  
  762.         of the screen.
  763.  
  764.         In this fashion, your programs can become MUCH smaller.
  765.  
  766.         OSG will prompt you for a file name to create. This file name  is  
  767.         the calling name that you will use within your programs, as  well  
  768.         as the OBJECT file name.
  769.  
  770.         The  object file that is created may be directly linked  into  an  
  771.         application program. It should be remembered that another section  
  772.         of  program code needs to be linked  in with the screen  that  is 
  773.         created.  This Object file is needed  only once. If you  have  12 
  774.         screens  in  a program, then your  effective  total  of  external 
  775.         OBJect  files  for  running  OSG screens  is  13.  This  file  is 
  776.         OSG.LIB.
  777.  
  778.         OSG directly generates OBJECT code, as described in the following  
  779.         documents:
  780.  
  781.         MS-DOS Programmers Reference Manual (P/N 036-014-012)
  782.         October 1985 issue of PC Tech Journal
  783.         8086 Relocatable Object Module Formats, Ver 4.0 (121748-001)
  784.  
  785.         Check  the  technical  appendix  for  information  on  both   the 
  786.         structure of the object files and the screen images.
  787.  
  788.         The  OBJECT  code  that  is generated may  be  linked  into  your  
  789.         application  using  the MSDOS LINK program, or generally  a  LINK  
  790.         program that was distributed with your programming language.
  791.  
  792.  
  793.  
  794.                     (c) 1987 Roy Barrow & Douglas H. Steen         13
  795.                       Object Code SCREEN GENERATOR - OSG
  796.  
  797.  
  798.         The  various LINK options may differ from language  to  language,  
  799.         and this is best covered in you language manual. You only need to 
  800.         know  that  you will be linking two files, the  screen  you  have  
  801.         generated  (extension  of  .OBJ)  and  the  video  support   file  
  802.         (OSG.LIB) . 
  803.  
  804.         OSG.EXE  is the program that will  produce the OBJECT files,  but 
  805.         each of these OBJECT files reference OSG.LIB, which is the  video 
  806.         driver. OSG's generated OBJECT files MUST be linked with OSG.LIB.
  807.  
  808.         If there is any confusion in this matter, please refer to  OBJECT  
  809.         linking  in  your  programming manual, or one  of  the  documents  
  810.         referred to above.
  811.  
  812.                           PRINT  FILE CREATION {ALT+P}
  813.  
  814.         A  print  file is a pure ASCII representation of  the  file  that 
  815.         exists  upon the screen. Although in general PRINT files  may  be 
  816.         used in helping to create user documentation, there are  problems 
  817.         associated  with  this.  The  ASCII file will  have  ALL  of  the 
  818.         characters that you placed upon the screen in it. This means that 
  819.         all of the control and extended characters will be included. 
  820.  
  821.         Now,  some control characters have affect upon your printer,  and 
  822.         one  in specific indicates an END of file to  many  applications. 
  823.         Naturally,  with so many environments, yours may have many  other 
  824.         problems character combinations associated with it. 
  825.  
  826.                                   QUIT {ALT+Q}
  827.  
  828.         It  is important to save the screens you work with, as  there  is 
  829.         almost always a need for it to be changed. Many people FORGET  to 
  830.         save  their  screens. That is why we have placed it in  the  QUIT 
  831.         option, so that you do NOT forget. 
  832.  
  833.         It  is a good idea to set up a MACRO key for saving  your  screen 
  834.         occasionally.  The MACRO definition will not continue and ask  if 
  835.         you  want  to  QUIT, as it will do from the  keyboard  prompt.
  836.  
  837.         Usually, saving the  screen is the last thing that you do  before 
  838.         you exit the program.  Just to ensure that you haven't  forgotten 
  839.         to do this, we placed  the SAVE option near QUIT!
  840.  
  841.         Both options prompt with "Are you sure" before actually quitting.  
  842.         There  should be little chance of losing a screen by a slip of  a  
  843.         key.  
  844.  
  845.         It  is recommended that the {ALT+Q} and the save option be   used 
  846.         regularly because you are BOUND to have a powerfailure when   you 
  847.         are  in  the  middle of designing the BEST  SCREEN  YET  SEEN  BY  
  848.         MANKIND. 
  849.  
  850.         The  other alternative is defining a MACRO which are a series  of 
  851.         these common keystrokes. That is, always do a SAVE before a  LOAD 
  852.         or a QUIT.
  853.  
  854.  
  855.                     (c) 1987 Roy Barrow & Douglas H. Steen         14
  856.                       Object Code SCREEN GENERATOR - OSG
  857.  
  858.  
  859.  
  860.                           REPLACE  A CHARACTER {ALT+R}
  861.  
  862.         REPLACE  is  a  simple way of  substituting  one  character  with 
  863.         another.  If the screen contains many drawing characters, it  may 
  864.         be  easier to use the replace option, rather than  redrawing  the 
  865.         sections.  The  character that is being replaced may   not  be  a 
  866.         space, not may the character replacing another  be a space. It is 
  867.         a  good  practice to SAVE the screen before such   a  search  and 
  868.         replace.
  869.  
  870.  
  871.                               {ALT+S} SELECT AND...
  872.  
  873.         {ALT+S}  is one of the most powerful commands in OSG.  With  this  
  874.         command you are able to
  875.  
  876.         Select an area of the screen and 
  877.  
  878.         copy it to another area
  879.         erase it completely
  880.         fill it with a solid color
  881.         invert the foreground and the background colors
  882.         re-color (change) the current color attributes
  883.  
  884.         Selecting  an area of the screen is done by using  the  selection  
  885.         box which has been discussed previously.
  886.  
  887.         Each  of  these options involves using a SELECTION BOX  which  is 
  888.         discussed  in  the  documentation. 
  889.  
  890.         PASTE allows an area to be selected and the 'dragged' and  copied 
  891.         to another area. The orginal area remains intact.ERASE allows the 
  892.         selected  area  to be set to blanks. 
  893.  
  894.         FILL  places  spaces  in the selected area with  a  chosen  color 
  895.         combination. 
  896.  
  897.         INVERT changes the color combinations (foreground to background). 
  898.         This  is  a  method of attaining colors  that  are  not  normally 
  899.         present in OSG. 
  900.  
  901.         CHANGE  COLORS does just that; it leaves that characters as  they 
  902.         currently exist, but just modified their attributes / colors.
  903.  
  904.  
  905.                               TAB SETTINGS {ALT+T}
  906.  
  907.         TABS  are  normally  set  (upon startup)  at  every  5  character 
  908.         intervals.  You have the option to change these intervals  or  to 
  909.         clear the TAB settings completely.                                                                  
  910.  
  911.         When  there  are  no  TAB settings, using TAB  (or  SHIFT  TAB  -  
  912.         Backwards) then the cursor will move to the next line but at  the 
  913.         same column co-ordinate. 
  914.  
  915.  
  916.                     (c) 1987 Roy Barrow & Douglas H. Steen         15
  917.                       Object Code SCREEN GENERATOR - OSG
  918.  
  919.  
  920.  
  921.         When used, TABS provide one of the fastest methods to get  around 
  922.         the  screens.  If you have 4 tabs set, for  instance,  you  could 
  923.         define  4 FUNCTION keys to move directly to those tab  positions. 
  924.         Here is an example:
  925.  
  926.                            VERSION AND DETAILS {ALT+V}
  927.  
  928.         This option displays whatever the current version of the  program 
  929.         is,  and  any details specific to that version. If you  have  any 
  930.         queries  about  the  use of this program, the  please  check  the 
  931.         version before contacting us. 
  932.  
  933.         NEW versions of OSG will be released from time to time, with  new 
  934.         features  - some of which are feedback from yourselves, and  some 
  935.         of which are our own consideration. 
  936.  
  937.         You may register your copy, and receive free assistance. Also, If 
  938.         you  need help, but you are not registered, then a SASE  will  do 
  939.         just fine. 
  940.  
  941.         {ALT+X} should be used only when you need to exit to DOS to run a  
  942.         program urgently. 
  943.  
  944.         YOU  MUST NEVER RUN A TSR (Terminate and Stay  Resident)  program 
  945.         when you have exited to DOS in this fashion. In  all  likelihood, 
  946.         you  will not be able to RETURN to OSG, and will  probably  CRASH 
  947.         the system. 
  948.  
  949.         EXIT  TO DOS You may 'SHELL' out to dos temporarily. Whilst  this 
  950.         is a useful feature, it is also a great way to crash your system! 
  951.         Be careful not to run any TSR's whilst in the DOS section. 
  952.  
  953.         If you are having a PROBLEM in shelling to DOS, please check  the 
  954.         amount of memory you have free. If this is not your problem, then 
  955.         check to see that COMMAND.COM is in your ROOT directory upon  the 
  956.         current  disk. Included is a description of the  general  editing 
  957.         functions. 
  958.  
  959.                           GENERAL   EDITING  FUNCTIONS
  960.  
  961.         [home] - Move to top left corner of screen 
  962.         [end] - Move to bottom right corner of screen 
  963.         [page up] - Move to top of screen 
  964.         [page down] - Move to bottom of screen 
  965.         [ctrl left arrow] - Move to left margin of the screen 
  966.         [ctrl right arrow] - Move to right margin of the screen 
  967.         [insert] - Toggle the Insert function on or off 
  968.         [delete]  -  Delete  the character to the right,  move  rest  one 
  969.         closer 
  970.         [backspace]  - Delete the character to the left, move the  cursor 
  971.         left 
  972.         [esc] - Repeat the last character or function [tab] - Move to the 
  973.         next Tab stop 
  974.         [shift tab] - Move to the prior Tab stop 
  975.  
  976.  
  977.                     (c) 1987 Roy Barrow & Douglas H. Steen         16
  978.                       Object Code SCREEN GENERATOR - OSG
  979.  
  980.  
  981.         [alt w] - Move to the start of the next word 
  982.         [alt k] - Move to the end of the previous word 
  983.         [ctrl w] - Show the current row & column co-ordinates 
  984.         [ctrl  a]  -  Choose  any  displayable  character  (also  not  on 
  985.         keyboard) 
  986.         [ctrl c] - Copy the above line to this line, move down one line 
  987.         [ctrl s] - Swap line with above, move one line up 
  988.  
  989.  
  990.  
  991.  
  992.  
  993.  
  994.  
  995.  
  996.  
  997.  
  998.  
  999.  
  1000.  
  1001.  
  1002.  
  1003.  
  1004.  
  1005.  
  1006.  
  1007.  
  1008.  
  1009.  
  1010.  
  1011.  
  1012.  
  1013.  
  1014.  
  1015.  
  1016.  
  1017.  
  1018.  
  1019.  
  1020.  
  1021.  
  1022.  
  1023.  
  1024.  
  1025.  
  1026.  
  1027.  
  1028.  
  1029.  
  1030.  
  1031.  
  1032.  
  1033.  
  1034.  
  1035.  
  1036.  
  1037.  
  1038.                     (c) 1987 Roy Barrow & Douglas H. Steen         17
  1039.                       Object Code SCREEN GENERATOR - OSG
  1040.  
  1041.  
  1042.                         APPENDIX - Technical Information
  1043.  
  1044.         The  screen storage format is in 2000 pairs of bytes.  The  first 
  1045.         byte  is  the  attribute for the character,  the  second  is  the 
  1046.         character  its'self.  This format can be gleaned  from  most  any 
  1047.         technical programming guide for the PC, too many to mention,  too 
  1048.         many good ones.
  1049.  
  1050.         Technical errata on screen object file:
  1051.  
  1052.         The purpose of this errata is to inform the technical user  about 
  1053.         specific   information  when  using  OSG  object  files   in   an 
  1054.         application.
  1055.  
  1056.         This  errata does not describe Microsoft/Intel object  files  and 
  1057.         assumes the reader has rudimentary knowledge of 8086 assembler. A 
  1058.         knowledge  of how assembly language routines are called from  the 
  1059.         development  language (BASIC,PASCAL, etc..) is also assumed.  The 
  1060.         manner  in which current MS-DOS languages call assembly  language 
  1061.         routines differ (sometimes drastically) and are beyond the  scope 
  1062.         of this errata.
  1063.  
  1064.         This  document  refers often to the  attached  assembly  language 
  1065.         source  listing (listing 1). This listing shows OSG  object  file 
  1066.         compatible source.
  1067.  
  1068.         The listing is used to illustrate the methods in which OSG object 
  1069.         files interact with other languages. The compression format  used 
  1070.         by  OSG  is  also documented as it is a  precursor  necessary  in 
  1071.         understanding the object file format.
  1072.  
  1073.         Before  examining  the actual object file specifics, it  will  be 
  1074.         beneficial  to  examine  the compression  method  OSG  uses.  OSG 
  1075.         compresses screen images by checking the attribute/character  for 
  1076.         a  screen  location.  Each location for a screen  row  (line)  is 
  1077.         checked    for    any   contiguous   pattern    of    the    same 
  1078.         attribute/character.   This  allows  a  line  of  spaces  to   be 
  1079.         compressed  into three bytes.If the  attribute/character  differs 
  1080.         from  the previous attribute/character, then OSG collects  unique 
  1081.         attributes/characters  until  OSG detects a  repeatable  pattern. 
  1082.         This process continues until each row (line) selected is checked.
  1083.  
  1084.         At  object  file  creation  time, OSG writes  out  each  line  in 
  1085.         compressed form as the 'data' part of the object file. Each group 
  1086.         of  repeatable/non-repeatable  attributes/characters  are  called 
  1087.         'character  group records'. Each character group record  has  the 
  1088.         following format:
  1089.  
  1090.                 -------------------------------///---------------
  1091.                 | Record  | Screen |  Attribute(s)/Character(s) |
  1092.                 | Length  | Offset |                            |
  1093.                 -------------------------------///---------------
  1094.  
  1095.         Record  length is the length of the character group  record  less 
  1096.         the record length byte itself. The format as is follows:
  1097.  
  1098.  
  1099.                     (c) 1987 Roy Barrow & Douglas H. Steen         18
  1100.                       Object Code SCREEN GENERATOR - OSG
  1101.  
  1102.  
  1103.  
  1104.                 7   6   5   4   3   2   1   0
  1105.               --------------------------------
  1106.               | R |       7 bit Length       |
  1107.               --------------------------------
  1108.  
  1109.         If  R  =  1  then the character  group  record  is  a  compressed 
  1110.         repeatable attribute/character and the 7 bit length specifies the 
  1111.         number  of instances the attribute/character should be  displayed 
  1112.         and only one attribute/character follows the record length  byte. 
  1113.         If R = 0 the 7 bit length specifies the number of  non-repeatable 
  1114.         attributes/characters  following  the record length byte  and  is 
  1115.         followed  by  the attributes/characters. If R = 0 and the  7  bit 
  1116.         length  = 0 then this is the last character group record  in  the 
  1117.         screen. This value is used to signal the end of the screen.
  1118.  
  1119.         The screen offset is an offset count into the screen ram  (number 
  1120.         of bytes from the beginning of screen ram). This is calculated by 
  1121.         OSG   to  relieve  the  assembly  language  output   routine   of 
  1122.         recalculating this offset from a row/column address each time the 
  1123.         screen is displayed. The screen offset value starts with 0 being 
  1124.         the first location on the screen.
  1125.  
  1126.         With  an  understanding  of the compression method  used,  and  a 
  1127.         definition of the character group record, the  remainder of  this 
  1128.         eratta  shall  be  devoted to the examination  of  the  assembler 
  1129.         source listing (listing 1). The first page is primarily  comments 
  1130.         and  non-essential  statements  used for the  commenting  of  the 
  1131.         assembler  source.  The  second page  starts  with  and  external 
  1132.         definition (EXTRN) of DISPLAY_SCREEN. DISPLAY_SCREEN is called by 
  1133.         the specific object file to output the character group records to 
  1134.         the  screen.  DISPLAY_SCREEN is responsible for  determining  the 
  1135.         type  of display and positioning the attribute/characters on  the 
  1136.         screen. DISPLAY_SCREEN is defined as far as it is impossible  (by 
  1137.         allowing  screen  object data to be larger than 64K) to  have  it 
  1138.         defined as a near call. 
  1139.  
  1140.         The  next  statement (SEGMENT) defines the segment in  which  our 
  1141.         screen  is  to reside. To allow then total number of  screens  to 
  1142.         exceed  64K bytes, each screen is given a unique segment name  by 
  1143.         combining  the screen name with a '_SEGMENT' suffix. All  of  the 
  1144.         screen  segments are aligned on byte boundaries, are public  (can 
  1145.         be  called by other modules external to this module) and  are  of 
  1146.         type class 'code'. This insures the screens reside in a safe area 
  1147.         away from stacks and dynamic data areas. 
  1148.  
  1149.         The  ASSUME  statement  tells the assembler  to  assume  how  the 
  1150.         assembler  program is going to initialize the  various  segments. 
  1151.         This  is  used  by  the  assembler  to  determine  far/near/short 
  1152.         distances  for instructions. Both the code segment (CS)  and  the 
  1153.         data segment (DS) assume we are going to use our screen segment.
  1154.  
  1155.         The PUBLIC statement specifies the name immediately following  as 
  1156.         being a public label. In an OSG object file that name is the name 
  1157.         of the screen.
  1158.  
  1159.  
  1160.                     (c) 1987 Roy Barrow & Douglas H. Steen         19
  1161.                       Object Code SCREEN GENERATOR - OSG
  1162.  
  1163.  
  1164.  
  1165.         The procedure definition (PROC) just below the public  definition 
  1166.         starts  the  screen  area and defines the area  as  being  a  far 
  1167.         procedure (this being the only safe assumption).
  1168.  
  1169.         The  CALL  statement calls the external  DISPLAY_SCREEN  routine. 
  1170.         DISPLAY_SCREEN  will  depend on the character  group  records  to 
  1171.         immediately follow the CALL. After DISPLAY_SCREEN has output  all 
  1172.         of  the  character  group  records, it  returns  to  the  calling 
  1173.         program.
  1174.  
  1175.         The  'DB' following the call is the start of the character  group 
  1176.         records.  The record length value (08H) specifies this is a  non-
  1177.         repeatable character group with a length of 8 attribute/character 
  1178.         pairs. The word value following (0080H) specifies an offset  into 
  1179.         screen    ram   by   0080H   locations.   Note   there   are    8 
  1180.         attribute/character  pairs  which matches  the  length  specified 
  1181.         above. 
  1182.  
  1183.         Immediately following the eighth attribute/character pair in  the 
  1184.         first  character  group record is the record length of  the  next 
  1185.         character  group record. Please note that the high order  bit  of 
  1186.         the length is set specifying this is a repeatable character group 
  1187.         record with a length of 020H. The word value following (0000H) is 
  1188.         the offset into the screen ram at location 0000H.
  1189.  
  1190.         The attribute/character pair following are to be replicated  020H 
  1191.         times starting at location 0000H in the screen ram. 
  1192.  
  1193.         The  byte following the repeatable character group record is  the 
  1194.         record  length  of the next character group record.  Please  note 
  1195.         then  record length is zero which signals DISPLAY_SCREEN that  it 
  1196.         has reached the end of the screen image to be output. 
  1197.  
  1198.         The  ENDP statement informs the assembler it has reached the  end 
  1199.         of the procedure. The ENDS statement informs the assembler it has 
  1200.         reached  the  end  of  the defined segment.  The  ENDS  and  ENDP 
  1201.         statements are required to terminate SEGMENT and PROC  statements 
  1202.         (respectively).  Finally the END statement is required to  inform 
  1203.         the assembler it has reached the end of the assembly source.
  1204.  
  1205.         In  an actual OSG object file certain labels/values are  replaced 
  1206.         with  labels/values. The following list may act a  guide  (please 
  1207.         note  that the braces are not included and 'screen.name'  is  the 
  1208.         name you have given the object file:
  1209.  
  1210.                 SCREENSG_SEGMENT - [screen.name]_SEGMENT
  1211.                 OUTPUTSC         - [screen.name]
  1212.  
  1213.         Example:  If  a  object file name was  chosen  as  MYSCREEN,  the 
  1214.         following would be the equivalent :
  1215.  
  1216.                 SCREENSG_SEGMENT - MYSCREEN_SEGMENT
  1217.                 OUTPUTSC         - MYSCREEN
  1218.  
  1219.  
  1220.  
  1221.                     (c) 1987 Roy Barrow & Douglas H. Steen         20
  1222.                       Object Code SCREEN GENERATOR - OSG
  1223.  
  1224.  
  1225.  
  1226.  
  1227.         Listing1 - sample listing
  1228.  
  1229.         Microsoft (R) Macro Assembler  Version 4.00                 1/12/87 10:28:16
  1230.  
  1231.         TEMPSCRN - template for screen display                      Page     1-1
  1232.                                                                     
  1233.  
  1234.                                          
  1235.                                                 TITLE   TEMPSCRN - template for screen display
  1236.                                          
  1237.                                          
  1238.                                                 PAGE    50,132 
  1239.                                         ;*** 
  1240.                                         ; TEMPSCRN 
  1241.                                         ; Purpose: 
  1242.                                         ;       To allow a BASIC Compiler program to output the included message 
  1243.                                         ;       to the screen. This is a template program to modified later (in  
  1244.                                         ;       object form) by a Microsoft Quickbasic program. 
  1245.                                         ; 
  1246.                                         ;       CALL OUTPUTSC 
  1247.                                         ; 
  1248.                                         ; Inputs: 
  1249.                                         ;       None 
  1250.                                         ; Outputs: 
  1251.                                         ;       None 
  1252.                                         ; 
  1253.                                         ; Modifies: 
  1254.                                         ;       08-22-1987 Add variable length screen files 
  1255.                                         ;*** 
  1256.         Listing1 - sample listing
  1257.  
  1258.         Microsoft (R) Macro Assembler  Version 4.00                 1/12/87 10:28:16
  1259.  
  1260.         TEMPSCRN - template for screen display                      Page     1-2
  1261.                                                                     
  1262.  
  1263.                                                 PAGE 
  1264.                                          
  1265.                                          
  1266.                                                 EXTRN   DISPLAY_SCREEN:FAR 
  1267.                                          
  1268.          0000                           SCREENSG_SEGMENT SEGMENT BYTE PUBLIC 'code' 
  1269.                                          
  1270.                                                 ASSUME  CS:SCREENSG_SEGMENT,DS:SCREENSG_SEGMENT 
  1271.                                          
  1272.                                                 PUBLIC  OUTPUTSC 
  1273.                                          
  1274.          0000                           OUTPUTSC        PROC FAR  
  1275.                                          
  1276.          0000  9A 0000 ---- E                   CALL    DISPLAY_SCREEN                  ; this will push the stack and offset to  
  1277.                                                                                         ; the stack, telling the program we call 
  1278.                                                                                         ; where to start displaying the data 
  1279.                                         ; 
  1280.  
  1281.  
  1282.                     (c) 1987 Roy Barrow & Douglas H. Steen         21
  1283.                       Object Code SCREEN GENERATOR - OSG
  1284.  
  1285.  
  1286.          0005  08                               db      08H                             ; the number of chars/attribs to transfer 
  1287.          0006  0080                             dw      0080H                           ; offset into the screen to write 
  1288.          0008  54 17 45 07 4D 17 50             db      "T",17H,"E",07H,"M",17H,"P",07H 
  1289.                07                       
  1290.          0010  54 17 49 07 4D 17 45             db      "T",17H,"I",07H,"M",17H,"E",07H 
  1291.                07                       
  1292.                                         ; 
  1293.          0018  A0                               db      0A0H                            ; the number of char/attribs to replicate 
  1294.          0019  0000                             dw      0000h                           ; offset to start replication 
  1295.          001B  2B 17                            db      "+",17H 
  1296.                                         ; 
  1297.          001D  00                               db      00                              ; the number of char/attribs = 0 to end 
  1298.                                                  
  1299.                                         ; 
  1300.                                         OUTPUTSC        ENDP 
  1301.          001E                           SCREENSG_SEGMENT        ENDS 
  1302.                                          
  1303.                                                 END 
  1304.         Listing1 - sample listing
  1305.  
  1306.         Microsoft (R) Macro Assembler  Version 4.00                 1/12/87 10:28:16
  1307.  
  1308.         TEMPSCRN - template for screen display                      Symbols-1
  1309.                                                                      
  1310.  
  1311.         Segments and Groups:
  1312.  
  1313.                         N a m e                 Size    Align   Combine Class
  1314.  
  1315.         SCREENSG_SEGMENT . . . . . . . .        001E    BYTE    PUBLIC  'CODE'
  1316.  
  1317.         Symbols:            
  1318.  
  1319.                         N a m e                 Type    Value   Attr         
  1320.  
  1321.         DISPLAY_SCREEN . . . . . . . . .        L FAR   0000            External
  1322.  
  1323.         OUTPUTSC . . . . . . . . . . . .        F PROC  0000    SCREENSG_SEGMENT        Global  Length = 001E
  1324.  
  1325.  
  1326.              54 Source  Lines
  1327.              54 Total   Lines
  1328.              25 Symbols
  1329.  
  1330.           50534 Bytes symbol space free
  1331.  
  1332.               0 Warning Errors
  1333.               0 Severe  Errors
  1334.  
  1335.  
  1336.  
  1337.  
  1338.  
  1339.  
  1340.  
  1341.  
  1342.  
  1343.                     (c) 1987 Roy Barrow & Douglas H. Steen         22
  1344.                       Object Code SCREEN GENERATOR - OSG
  1345.  
  1346.  
  1347.                             APPENDIX - BOX SELECTION
  1348.  
  1349.         Throughout  OSG, there will be occasion to choose  a  rectangular 
  1350.         area  upon the screen. This could be a small section or the whole                               
  1351.         screen. 
  1352.  
  1353.         In selecting an area of the screen, a rectangle will appear which 
  1354.         is  locatable. This rectangle should be placed over the  area  of 
  1355.         the  screen  that you would like to select. In  doing  this,  the 
  1356.         sides  of  the box may be moved. There are specific  controls  in 
  1357.         moving the sized of this box.
  1358.  
  1359.         A summary of the command keys for positioning and selecting  this  
  1360.         box follows.
  1361.  
  1362.         {HOME}
  1363.         Expands the selection box so that it fills the whole screen.
  1364.  
  1365.         {END}
  1366.         Contracts  the  box size so that it only covers a  small  central  
  1367.         area.  When  first  entering the selection,  this  or  {HOME}  is  
  1368.         usually one of the first keys pressed in selecting an area.
  1369.  
  1370.         {PgUp}
  1371.         Two functions are accomplished. The rectangle will 'grow' in  all  
  1372.         directions (up, down, left and right). If a boundary (or  border) 
  1373.         is  reached,  then this function is  disabled, but  others  exist 
  1374.         that  allow  the  box to grow upwards and   downwards  only,  and 
  1375.         another that allow it to grow sideways only.
  1376.  
  1377.         {PgDn}
  1378.         This  performs  the  opposite  of {PgUp}  -  the  rectangle  will  
  1379.         shrink.
  1380.  
  1381.         {INS}
  1382.         Increases the width of the selection box on both sides. Again, if  
  1383.         a boundary of the screen is reached, pressing {INS} will have  no  
  1384.         effect.
  1385.  
  1386.         {DEL}
  1387.         Reduces  the width of the selection box, performing the  opposite  
  1388.         of {INS}.
  1389.  
  1390.         {Ctrl-PgUp}
  1391.         Increases  the  height and depth of the  selection  box,  limited 
  1392.         again  by the boundary.
  1393.  
  1394.         {Ctrl-PgDn}
  1395.         Performs  the opposite of {Ctrl-PgUp}. A corner of the  selection 
  1396.         box  is  ALWAYS selected. This corner can  be  discerned  by  the 
  1397.         Double  width  Corner character that will  appear on one  of  the 
  1398.         corners.  
  1399.  
  1400.         This selection may be moved by pressing the {TAB} key.
  1401.  
  1402.  
  1403.  
  1404.                     (c) 1987 Roy Barrow & Douglas H. Steen         23
  1405.                       Object Code SCREEN GENERATOR - OSG
  1406.  
  1407.  
  1408.         The  currently selected corner may be expanded or  contracted  by  
  1409.         using a cursor key. 
  1410.  
  1411.         When  {SCROLL LOCK} is depressed, a cursor key will MOVE the  box  
  1412.         around  the screen instead of allowing it to expand or  contract.  
  1413.         Most   keyboards  have  Scroll  Lock  LED's,  but  if   you   are  
  1414.         experiencing  problems with box sizing, then try  {SCROLL  LOCK},  
  1415.         and then try your cursor option again.
  1416.  
  1417.  
  1418.                             APPENDIX - Using OSGBASIC
  1419.  
  1420.         OSGBASIC is a program that will call up screen images, and  allow 
  1421.         you to create input definitions. It is simple to use.
  1422.  
  1423.         Initially, after having selected a screen to use, you should move 
  1424.         your cursor to a point where you would like an Input Definition.
  1425.  
  1426.         Press  Return, then answer questions about the variable that  you 
  1427.         would like input at that point.
  1428.  
  1429.         Go through this for as many variables as you like (IN SEQUENCE of 
  1430.         how  you wish the questions answered), and press ESC  when  asked 
  1431.         for a varaible name when you are finished.
  1432.  
  1433.         The  Input  Libraries are available Only on registration  of  OSG 
  1434.         Lvele 2 or Level 3.
  1435.  
  1436.         Hope you enjoy these programs.
  1437.  
  1438.         Roy Barrow
  1439.         9-October-1987
  1440.  
  1441.  
  1442.  
  1443.  
  1444.  
  1445.  
  1446.  
  1447.  
  1448.  
  1449.  
  1450.  
  1451.  
  1452.  
  1453.  
  1454.  
  1455.  
  1456.  
  1457.  
  1458.  
  1459.  
  1460.  
  1461.  
  1462.  
  1463.  
  1464.  
  1465.                     (c) 1987 Roy Barrow & Douglas H. Steen         24
  1466.                       Object Code SCREEN GENERATOR - OSG
  1467.  
  1468.  
  1469.                             REGISTRATION INFORMATION
  1470.  
  1471.         Registering  OSG  will bring you the source code for all  of  the 
  1472.         programs mentioned in this documentation - everything you need.
  1473.  
  1474.         To register, please send a check for one of:
  1475.  
  1476.         1) $13 - No source, just feel good, get a free update
  1477.         2) $26 - Manual, free updates for a year
  1478.         3) $39 - Source code, manual, free updates for a year
  1479.         4) $49 - ALL of option 4, plus QBTOOLS source code
  1480.  
  1481.                                  Our address is:
  1482.  
  1483.                            Inventories Unlimited Inc.
  1484.                                 222 Church Street
  1485.                              Philadelphia, PA 19106
  1486.  
  1487.                              (215) 922-2557 (Voice)
  1488.                               (215) 627-3910 (Data)
  1489.  
  1490.  
  1491.  
  1492.  
  1493.  
  1494.  
  1495.  
  1496.  
  1497.  
  1498.  
  1499.  
  1500.  
  1501.  
  1502.  
  1503.  
  1504.  
  1505.  
  1506.  
  1507.  
  1508.  
  1509.  
  1510.  
  1511.  
  1512.  
  1513.  
  1514.  
  1515.  
  1516.  
  1517.  
  1518.  
  1519.  
  1520.  
  1521.  
  1522.  
  1523.  
  1524.  
  1525.  
  1526.                     (c) 1987 Roy Barrow & Douglas H. Steen         25
  1527.